package com.xinqing.test.LetCode;

/**
 * @Author:CHQ
 * @Date:2021/7/21 9:58
 * @Description
 */
public class MissingNumber {
    public static void main(String[] args) {


        int[] nums={0,1,2,4};

        int x=nums.length;

        for(int i=0;i<x;i++){
            x^=nums[i];
            x^=i;
        }

        System.out.println(x);

    }
}
